import request from '@/utils/request'

/*初始化考试记录，并获取试卷信息：包括考试时间、总分，题目选项*/
export function getTestPaper(data) {
  return request({
    url: '/courseCenter/tbExam/startTest',
    method: 'post',
    data
  })
}

/*下一步提交该题作答*/
export function commitTheProblem(data) {
  return request({
    url: '/courseCenter/tbExam/nextProblem',
    method: 'post',
    data
  })
}

/*获取历史作答*/
export function getAnswerHistory(data) {
  return request({
    url: '/courseCenter/tbExam/getAnswerSituation',
    method: 'post',
    data
  })
}

/*完成作答*/
export function finishTest(data) {
  return request({
    url: '/courseCenter/tbExam/finishTest',
    method: 'post',
    data
  })
}

/*结果详情页面：拉取遴选结果*/
export function getTestSuitation(examId) {
  return request({
    url: '/courseCenter/tbExam/getTestSuitation',
    method: 'post',
    params: {examId}
  })
}


/*获取自定义题目列表*/
export function getTestCustomAskSiutation(selectRecordId, userId) {
  return request({
    url: '/selectCenter/tbApplicant/getTestCustomAskSiutation',
    method: 'post',
    params: {selectRecordId, userId}
  })
}

/*批改自定义题目  下一题接口*/
export function correctCustom(data) {
  return request({
    url: '/courseCenter/answertSheet/correctCustom',
    method: 'post',
    data
  })
}



